include:
  - app.jobseekers.local-core

Check out JobSeekers Mobile Code:
  svn.latest:
    - name: svn://svn-pg.jobstreet.com/mobile/trunk
    - target: /tmp/svn/JobSeekers/mobile
    - user: lighttpd
    - username: ciuser
    - password: automation
    - unless: test -d /var/www/seekasia.com/JobSeekers/mobile

Checkout local dev Sub SVN Module for JobSeekers Mobile:
  svn.latest:
    - name: svn://svn-pg.jobstreet.com/JobSeekers/trunk/job-search/Model/JobSearch
    - target: /tmp/svn/JobSeekers/mobile/Model/JobSearch
    - user: lighttpd
    - username: ciuser
    - password: automation
    - unless: test -d /var/www/seekasia.com/JobSeekers/mobile

Copy local dev JobSeekers Mobile Code to destination:
  cmd.run:
    - name: cp -r /tmp/svn/JobSeekers/mobile /var/www/seekasia.com/JobSeekers/
    - unless: test -d /var/www/seekasia.com/JobSeekers/mobile

Run JobSeekers Mobile composer:
  cmd.run:
    - name: php composer.phar install
    - cwd: /var/www/seekasia.com/JobSeekers/mobile/
    - unless: test -d /var/www/seekasia.com/JobSeekers/mobile/vendor

Setup local dev MyJS Symlink for JobSeekers Mobile:
  file.symlink:
    - name: /var/www/seekasia.com/JobSeekers/myjs11.7
    - target: myjs11
    - user: lighttpd
    - mode: 777

Setup local dev JobSeekers Mobile Controller API Symlink:
  file.symlink:
    - name: /var/www/html/myjs11/mobile-api
    - target: /var/www/seekasia.com/JobSeekers/mobile/Controller/api
    - user: lighttpd
    - mode: 777

Setup local dev JobSeekers Mobile Controller Symlink:
  file.symlink:
    - name: /var/www/html/mobile
    - target: /var/www/seekasia.com/JobSeekers/mobile/Controller

Setup local dev JobSeekers Mobile Controller Static Symlink:
  file.symlink:
    - name: /var/www/html/mobile-static
    - target: /var/www/seekasia.com/JobSeekers/mobile/Static